Namespace Helpers

    Public Class CursorHelper
        Private mBusyCount As Integer = 0

        Public Sub SetBusy()
            mBusyCount += 1
            If mBusyCount = 1 Then
                Cursor.Current = System.Windows.Forms.Cursors.WaitCursor
            End If
        End Sub
        Public Sub SetFree()
            If mBusyCount = 0 Then Return
            mBusyCount -= 1
            If mBusyCount = 0 Then
                Cursor.Current = System.Windows.Forms.Cursors.Default
            End If
        End Sub

    End Class

End Namespace
